package com.zhongshengnetwork.rightbe.dbmodel;

import android.util.Log;

import com.zhongshengnetwork.rightbe.CustomApplication;

import org.xutils.db.annotation.Column;
import org.xutils.db.annotation.Table;

/**
 * Created by GordonLjx on 2016/9/25.
 */
@Table(name = "logindb")//table
public class LogindbModel {
    @Column(name = "uid", isId = true)
    private String uid;
    @Column(name = "rctoken")
    private String rctoken;
    @Column(name = "token")
    private String token;
    @Column(name = "expires")
    private String expires;
    @Column(name = "header")
    private String header;
    @Column(name = "thumbheader")
    private String thumbheader;
    @Column(name = "background")
    private String background;
    @Column(name = "nickname")
    private String nickname;
    @Column(name = "sex")
    private String sex;
    @Column(name = "signature")
    private String signature;
    @Column(name = "location")
    private String location;
    @Column(name = "userauth")
    private String userauth;
    @Column(name = "payauth")
    private String payauth;

    @Column(name = "weiJuId")
    private String weiJuId;

    @Column(name = "mobile")
    private String mobile;

    @Column(name = "need")
    private String need; //0-需要绑定手机号；1-不需要绑定手机号

    public String getUid() {
        return uid;
    }

    public void setUid(String uid) {
        this.uid = uid;
    }

    public String getRctoken() {
        return rctoken;
    }

    public void setRctoken(String rctoken) {
        this.rctoken = rctoken;
    }

    public String getToken() {
        if (token != null && token.contains("a-")){
            CustomApplication.isAutoLogin = true;
        }else {
            CustomApplication.isAutoLogin = false;
        }
        //Log.e("TAG","token="+token);
        return token;
    }

    public void setToken(String token) {
        this.token = token;
    }

    public String getExpires() {
        return expires;
    }

    public void setExpires(String expires) {
        this.expires = expires;
    }

    public String getHeader() {
        return header;
    }

    public void setHeader(String header) {
        this.header = header;
    }

    public String getThumbheader() {
        return thumbheader;
    }

    public void setThumbheader(String thumbheader) {
        this.thumbheader = thumbheader;
    }

    public String getBackground() {
        return background;
    }

    public void setBackground(String background) {
        this.background = background;
    }

    public String getNickname() {
        return nickname;
    }

    public void setNickname(String nickname) {
        this.nickname = nickname;
    }

    public String getSex() {
        return sex;
    }

    public void setSex(String sex) {
        this.sex = sex;
    }

    public String getSignature() {
        return signature;
    }

    public void setSignature(String signature) {
        this.signature = signature;
    }

    public String getLocation() {
        return location;
    }

    public void setLocation(String location) {
        this.location = location;
    }

    public String getUserauth() {
        return userauth;
    }

    public void setUserauth(String userauth) {
        this.userauth = userauth;
    }

    public String getPayauth() {
        return payauth;
    }

    public void setPayauth(String payauth) {
        this.payauth = payauth;
    }

    public String getWeiJuId() {
        return weiJuId;
    }

    public void setWeiJuId(String weiJuId) {
        this.weiJuId = weiJuId;
    }

    public String getMobile() {
        return mobile;
    }

    public void setMobile(String mobile) {
        this.mobile = mobile;
    }

    public String getNeed() {
        return need;
    }

    public void setNeed(String need) {
        this.need = need;
    }
}
